package com.sniper.springmvc.scheduler;

public enum TaskStatus {
    //开始，暂停，继续，停止，运行一次，阻塞，错误，删除
    START, PAUSE, CONTINUE, STOP, RUNONCE, BLOCKING, ERROR, DELETE;

    private TaskStatus() {
    }

    public static TaskStatus toTaskStatus(String str) {
        try {
            return valueOf(str.toUpperCase());
        } catch (Exception e) {
            return ERROR;
        }
    }

}
